<!DOCTYPE html>
<html>
<head>
    <title>Azure POS Data Collection Solution</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            max-width: 800px;
            margin: 0 auto;
            padding: 20px;
            line-height: 1.6;
        }
        .question {
            margin-bottom: 20px;
            background-color: #f9f9f9;
            padding: 15px;
            border-radius: 5px;
        }
        .options {
            margin: 20px 0;
        }
        .option {
            margin: 15px 0;
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
            background-color: white;
        }
        .option label {
            display: flex;
            align-items: center;
            cursor: pointer;
        }
        .option input {
            margin-right: 10px;
        }
        button {
            margin-top: 20px;
            padding: 10px 15px;
            background-color: #0078d4;
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 16px;
        }
        button:hover {
            background-color: #106ebe;
        }
        #answer {
            margin-top: 20px;
            padding: 15px;
            background-color: #f3f2f1;
            border-radius: 4px;
            display: none;
        }
        .correct-answer {
            font-weight: bold;
            color: #107c10;
        }
        .explanation {
            margin-top: 15px;
        }
        .note {
            font-style: italic;
            color: #666;
            margin-bottom: 15px;
        }
    </style>
</head>
<body>
    <div class="question">
        <h2>QUESTION NO: 110</h2>
        <p class="note">Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.</p>
        <p class="note">After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.</p>
        
        <p>You are developing an Azure solution to collect point-of-sale (POS) device data from 2,000 stores located throughout the world. A single device can produce 2 megabytes (MB) of data every 24 hours. Each store location has one to five devices that send data.</p>
        <p>You must store the device data in Azure Blob storage. Device data must be correlated based on a device identifier. Additional stores are expected to open in the future.</p>
        <p>You need to implement a solution to receive the device data.</p>
        
        <p><strong>Solution:</strong> Provision an Azure Service Bus. Configure a topic to receive the device data by using a correlation filter.</p>
        <p>Does the solution meet the goal?</p>
    </div>
    
    <div class="options">
        <div class="option">
            <label>
                <input type="radio" name="solution" value="A"> A. Yes
            </label>
        </div>
        <div class="option">
            <label>
                <input type="radio" name="solution" value="B"> B. No
            </label>
        </div>
    </div>
    
    <button onclick="showAnswer()">查看答案</button>
    
    <div id="answer">
        <p><strong>正确答案:</strong> <span class="correct-answer">A. Yes</span></p>
        
        <div class="explanation">
            <p><strong>说明:</strong></p>
            <ol>
                <li><strong>Service Bus适用性验证:</strong>
                    <ul>
                        <li>Azure Service Bus专为高价值企业消息设计（如订单处理、金融交易）</li>
                        <li>POS设备数据属于结构化交易数据，符合Service Bus典型场景</li>
                        <li>消息大小2MB/设备/天在Service Bus标准层处理范围内（单消息最大1MB，但日均总量可扩展）</li>
                    </ul>
                </li>
                
                <li><strong>架构实现分析:</strong>
                    <ul>
                        <li>设备ID关联可通过Service Bus的<strong>会话ID(SessionId)</strong>或<strong>关联过滤器(Correlation Filter)</strong>实现</li>
                        <li>2000个门店×5设备的规模（约10,000终端）适合Service Bus Premium层</li>
                        <li>与Blob存储集成可通过Azure Functions触发完成</li>
                    </ul>
                </li>
                
                <li><strong>对比其他服务:</strong>
                    <ul>
                        <li>Event Hubs更适合流式数据（如日志、遥测），但缺乏消息关联机制</li>
                        <li>Event Grid是事件通知服务，不存储消息体</li>
                    </ul>
                </li>
                
                <li><strong>扩展性保障:</strong>
                    <ul>
                        <li>Service Bus自动扩展单元(Auto-inflate)可应对未来门店增长</li>
                        <li>支持通过Azure门户或API动态调整吞吐量单位(TUs)</li>
                    </ul>
                </li>
            </ol>
            
            <p>因此，该解决方案<strong>能够</strong>满足需求，正确答案是<strong>A. Yes</strong>。</p>
        </div>
    </div>
    
    <script>
        function showAnswer() {
            document.getElementById("answer").style.display = "block";
            // Auto-select the correct answer
            document.querySelector('input[value="A"]').checked = true;
        }
    </script>
</body>
</html>
